﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Huirui.Cavan.Domain.MainBoundedContext.ReportModule;
using Spring.Data.Generic;

namespace Huirui.Cavan.Infrastructure.Data.MainBoundedContext.PurchaseModule
{
    public class PayReportMapper : IRowMapper<PayReport>
    {
        #region IRowMapper<PayReport> 成员

        public PayReport MapRow(System.Data.IDataReader reader, int rowNum)
        {
            PayReport report = new PayReport();
            report.PayCode = reader.GetString(0);
            report.PayDate = reader.GetDateTime(1);
            report.SupplierCode = reader.GetString(2);
            report.SupplierName = reader.GetString(3);
            report.Currency = reader.GetString(4);
            report.CurrencyRate = reader.GetDecimal(5);
            report.Amount = reader.GetDecimal(6);
            report.AccountCode = reader.GetString(7);
            report.AccountNumber = reader.GetString(8);
            report.Remark = reader.GetString(9);

            return report;
        }

        #endregion(
    }
}
